package com.atguigu.dwm.model.mapper;

import com.atguigu.dwm.model.bean.DmDimension;
import com.atguigu.dwm.model.bean.DmModifier;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import com.baomidou.dynamic.datasource.annotation.DS;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 限定词表 Mapper 接口
 * </p>
 *
 * @author zhangchen
 * @since 2024-07-04
 */
@Mapper
@DS("dwm")
public interface DmModifierMapper extends BaseMapper<DmModifier> {
    @Select("select  t.*,dw.model_name  from dm_modifier t \n" +
            "   left join dp_data_warehouse_model  dw on t.model_id=dw.id\n" +
            "where t.is_deleted='0'  ${condition}")
    List<DmModifier> selectQueryList(String condition);

    @Select("select  count(*)  from dm_modifier t \n" +
            "where t.is_deleted='0'  ${condition}")
    Integer selectQueryCount(String condition);
}
